define(['app'], function(app) {
	'use strict';

	//实例化方法
	var factory = function(Http) {
		
		//返回信息
		return {
			//品牌管理
            brand_list: function(nPage, callback, calldone) {
                Http.post({
                    method: 'member.brand.getlist',
                    pagelimit:10,
                    nPage: nPage
                }, function(result) {
                    if(callback)
                        callback(result.result);
                }, function(e) {

                }, function() {
					if(calldone)
						calldone();
                })
            },
            //删除品牌
            delete_brand: function(brand_id, callback) {
                Http.post({
                    method: 'member.brand.delete',
                    brand_id:brand_id
                }, function(result) {
                    if(callback)
                    	callback(result);
                }, function(e) {

                }, function() {

                })
            },
			
		};
	}

	factory.$inject = ['Http'];
	return app.registerService("Productmanager_brand", factory);
});